RequireUIFile('jquery-ui.css', ApplicationFramework::ORDER_FIRST); $GLOBALS["AF"]->RequireUIFile('jquery-ui.js', ApplicationFramework::ORDER_FIRST); # ----- EXPORTED FUNCTIONS --------------------------------------------------- /** * Print a text metadata field row. * @param MetadataField $Field text metadata field */ function PrintTextFieldRow(MetadataField $Field) { $P = new MfeFieldValuePrinter($Field); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> DefaultValue(); ?> N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> MaxLength(); ?> AllowHTML(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> MaxLength(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> MaxLength(); ?> N/A N/A N/A N/A N/A N/A N/A i>N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> DefaultValue(); ?> N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A N/A N/A AllowHTML(); ?> ParagraphRows(); ?> ParagraphCols(); ?> UseWysiwygEditor(); ?> N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> DefaultValue(); ?> N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> N/A N/A N/A N/A N/A MinValue(); ?> MaxValue(); ?> N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A UpdateMethod(); ?> UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInAdvancedSearch(); ?> N/A IncludeInSortOptions(); ?> SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> DefaultValue(); ?> N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A FlagOnLabel(); ?> FlagOffLabel(); ?> N/A N/A N/A N/A IncludeInAdvancedSearch(); ?> N/A N/A N/A
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> UseForOaiSets(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A NumAjaxResults(); ?> N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> IncludeInFacetedSearch(); ?> N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> UseForOaiSets(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A NumAjaxResults(); ?> N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> IncludeInFacetedSearch(); ?> N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A AllowMultiple(); ?> N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> UseForOaiSets(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> IncludeInFacetedSearch(); ?> N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A UserPrivilegeRestrictions(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A AllowMultiple(); ?> N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A IncludeInKeywordSearch(); ?> IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> DefaultValue(); ?> N/A N/A N/A UsesQualifiers(); ?> HasItemLevelQualifiers(); ?> DefaultQualifier(); ?> AssociatedQualifierList(); ?> ShowQualifiers(); ?> N/A TextFieldSize(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A PointPrecision(); ?> PointDecimalDigits(); ?> N/A IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A NumAjaxResults(); ?> N/A N/A N/A IncludeInAdvancedSearch(); ?> N/A N/A SearchWeight(); ?>
Enabled(); ?> Editable(); ?> Optional(); ?> N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A N/A SearchWeight(); ?>
MetadataField = $MetadataField; $this->HumanField = new HumanMetadataField($MetadataField); $this->HumanField->SetNotSetText("—"); } /** * Escape for HTML and print the value returned from * $this->HumanField->$Method($Arguments). * @param string $Method method name * @param array $Arguments method arguments */ public function __call($Method, $Arguments) { $Callback = [$this->HumanField, $Method]; $Value = call_user_func_array($Callback, $Arguments); print defaulthtmlentities($Value); } /** * Print a 1 if the metadata field can be toggled (enabled/disabled) or a 0 * if it can't be. */ public function fieldIsTogglable() { if (!isset(self::$ActivePlugins)) { global $G_PluginManager; self::$ActivePlugins = $G_PluginManager->GetActivePluginList(); } $Id = $this->MetadataField->Id(); $Owner = $this->MetadataField->Owner(); $OwnerIsActive = in_array($Owner, self::$ActivePlugins); if (SystemConfiguration::getInstance()->getBool("ResourceRatingsEnabled") && $this->MetadataField->Name() == "Cumulative Rating") { $IsTogglable = false; } else { $Schema = new MetadataSchema($this->MetadataField->SchemaId()); $IsTogglable = !$Schema->FieldToStdNameMapping($Id) && !MetadataSchema::FieldUsedInPrivileges($Id); $IsTogglable = $IsTogglable && (!$Owner || $OwnerIsActive); } print defaulthtmlentities($IsTogglable ? "1" : "0"); } /** * @var array $ActivePlugins static array of active (enabled) plugins */ protected static $ActivePlugins; /** * @var MetadataField $MetadataField metadata field */ protected $MetadataField; /** * @var HumanMetadataField $HumanField $this->MetadataField wrapped in a * HumanMetadataField object */ protected $HumanField; } /** * Get the display text for the field, which includes the display name and the * name in parentheses if a label is set. The text will be properly escaped * HTML. * @param MetadataField $Field metadata field * @return the display text for the field as escaped HTML */ function getFieldInfoDisplayText(MetadataField $Field) { $DisplayName = defaulthtmlentities($Field->GetDisplayName()); $Name = defaulthtmlentities($Field->Name()); return $DisplayName . (strlen($Field->Label()) ? " (".$Name.")" : ""); } /** * Print "enabled" or "disabled" if the field is enabled or disabled, * respectively. * @param MetadataField $Field metadata field */ function printEnabledText(MetadataField $Field) { print $Field->Enabled() ? "enabled" : "disabled"; } /** * Print the escaped metadata field ID. * @param MetadataField $Field metadata field */ function printFieldIdText(MetadataField $Field) { print defaulthtmlentities($Field->Id()); } /** * Print the metadata field name text, which includes a link to the field * editing page, the name of the field, the label of the field, and a help * tooltip containing the field description. * @param MetadataField $Field metadata field */ function printFieldNameText(MetadataField $Field) { global $AF; $SafeFieldId = defaulthtmlentities($Field->Id()); $SafeFieldName = defaulthtmlentities(GetFieldInfoDisplayText($Field)); $TooltipId = "mv-dialog-".$SafeFieldId; $HelpImage = $Field->Enabled() ? "help.png" : "help_disabled.png"; ?> getInterfaceSetting("TooltipsUseDialogs")) { ?>

Description()) ?>

Id()); ?> Edit Id()] = $Schema->ResourceName() . " Schema"; } $OptList = new HtmlOptionList("SC", $Options, $SchemaInUse->Id()); $OptList->SubmitOnChange(true); $OptList->PrintHtml(); } # ----- MAIN ----------------------------------------------------------------- $SafeSchemaId = defaulthtmlentities($H_Schema->Id()); $ChosenView = StdLib::getArrayValue($_GET, "View", "Metadata"); $Views = [ "Metadata" => ".mfe-group-metadata", "Display" => ".mfe-group-display", "Search" => ".mfe-group-search" ]; # remove the chosen view unset($Views[$ChosenView]); # settings that should not be displayed or otherwise used $DisabledSettings = [ ".mfe-field-userprivilegerestrictions", ".mfe-field-updatemethod", ".mfe-field-showqualifiers", ".mfe-field-associatedqualifierlist", ".mfe-field-useforoaisets", ".mfe-field-paragraphrows", ".mfe-field-paragraphcols", ".mfe-field-usewysiwygeditor", ".mfe-field-minvalue", ".mfe-field-maxvalue", ".mfe-field-flagonlabel", ".mfe-field-flagofflabel", ".mfe-field-pointprecision", ".mfe-field-pointdecimaldigits" ]; ?> getInterfaceSetting("TooltipsUseDialogs")) { ?>
requireUIFile("CW-Tooltips.js"); } ?>

In order for the Search settings updates to take place, please rebuild the search database.

# Metadata Field Editor

Add New Field Edit

- " id="displayMetadataOnly" href="index.php?P=DBEditor&View=Metadata">Metadata
- " id="displayDisplayOnly" href="index.php?P=DBEditor&View=Display">Display
- " id="displaySearchOnly" href="index.php?P=DBEditor&View=Search">Search

Hide Disabled Fields

Enabled | Field Name | Editable | Optional | Default Value | Allow Multiple | Restrict to | Update Method | Uses Qualifiers | Item-Level Qualifiers | Default Qualifier | Allowed Qualifiers | Show Qualifiers | Use for OAI Sets | Field Size | Max Length | Allow HTML | Rows | Columns | WYSIWYG | Min Value | Max Value | Flag On Label | Flag Off Label | Max Number of Search Results | Precision | Decimal Digits | Include in Keyword Search | Include in Advanced Search | Include in Faceted Search | Include in Sort Options | Search Weight | Edit
--- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | ---
Enabled | Field Name | Editable | Optional | Default Value | Allow Multiple | Restrict to | Update Method | Uses Qualifiers | Item-Level Qualifiers | Default Qualifier | Allowed Qualifiers | Show Qualifiers | Use for OAI Sets | Field Size | Max Length | Allow HTML | Rows | Columns | WYSIWYG | Min Value | Max Value | Flag On Label | Flag Off Label | Max Number of Search Results | Precision | Decimal Digits | Include in Keyword Search | Include in Advanced Search | Include in Faceted Search | Include in Sort Options | Search Weight | Edit
GetFields(MetadataSchema::MDFTYPE_TEXT, null, true))) { ?>
Text Fields
GetFields(MetadataSchema::MDFTYPE_URL, null, true))) { ?>
Url Fields
GetFields(MetadataSchema::MDFTYPE_EMAIL, null, true))) { ?>
Email Fields
GetFields(MetadataSchema::MDFTYPE_PARAGRAPH, null, true))) { ?>
Paragraph Fields
GetFields(MetadataSchema::MDFTYPE_NUMBER, null, true))) { ?>
Number Fields
GetFields(MetadataSchema::MDFTYPE_DATE, null, true))) { ?>
Date Fields
GetFields(MetadataSchema::MDFTYPE_TIMESTAMP, null, true))) { ?>
Timestamp Fields
GetFields(MetadataSchema::MDFTYPE_FLAG, null, true))) { ?>
Flag Fields
GetFields(MetadataSchema::MDFTYPE_TREE, null, true))) { ?>
Tree Fields
GetFields(MetadataSchema::MDFTYPE_CONTROLLEDNAME, null, true))) { ?>
Controlled Name Fields
GetFields(MetadataSchema::MDFTYPE_OPTION, null, true))) { ?>
Option Fields
GetFields(MetadataSchema::MDFTYPE_USER, null, true))) { ?>
User Fields
GetFields(MetadataSchema::MDFTYPE_FILE, null, true))) { ?>
File Fields
GetFields(MetadataSchema::MDFTYPE_IMAGE, null, true))) { ?>
Image Fields
GetFields(MetadataSchema::MDFTYPE_POINT, null, true))) { ?>
Point Fields
GetFields(MetadataSchema::MDFTYPE_REFERENCE, null, true))) { ?>
Reference Fields
GetFields( MetadataSchema::MDFTYPE_SEARCHPARAMETERSET, null, true ))) { ?>
Search Parameter Set Fields

Add New Field